//
//  SEGEquipmentFormListModel.h
//  Uhomebk
//
//  Created by mac on 2017/7/5.
//  Copyright © 2017年 com.segi. All rights reserved.
//  巡更时spotDetailId有值，巡检时equipmentDtInstId有值。

#import <Foundation/Foundation.h>
#import "SEGBaseDataModel.h"

@interface SEGTemplateModel : SEGBaseDataModel
@property (nonatomic, copy) NSString * attrInstId;/**属性id */
@property (nonatomic, copy) NSString * seq;/** 顺序号 */
@property (nonatomic, copy) NSString * disGroupid;/**属性显示分组 */
@property (nonatomic, copy) NSString * widgetType;/**控件类型 */
@property (nonatomic, copy) NSString * contentLengthLimit;/**内容限制的长度 */
@property (nonatomic, copy) NSString * title;/**标题 */
@property (nonatomic, copy) NSString * markedWords;/**提示语 */
@property (nonatomic, copy) NSString * expressCode;/**正则表达式，判断输入数据是否满足条件 */
@property (nonatomic, copy) NSString * attrValueType;/**属性值type( 1.枚举值, 2.用户输入,3.固定值) */
@property (nonatomic, copy) NSString * readable;/**读权限 */
@property (nonatomic, copy) NSString * writable;/**写权限 */
@property (nonatomic, copy) NSString * required;/**是否必填 */
@property (nonatomic, copy) NSString * attrValue;/**属性值 2、3时参考 */
@property (nonatomic, copy) NSString * attrCode;/**属性编码 */
@property (nonatomic, strong) NSString *defaultData;/**初始化数据 */

@property (nonatomic, strong) NSMutableDictionary * mDictionary;

+ (instancetype)initWithDictionary:(NSDictionary*)dictionary;

@end

//otherFormList模型
@interface SEGOtherFormsList : SEGBaseDataModel
@property (nonatomic, copy) NSString * equipmentDtInstId;//巡检
@property (nonatomic, copy) NSString * spotDetailId;//巡更
@property (nonatomic, copy) NSString * _id;//id
@property (nonatomic, strong) NSArray <SEGTemplateModel *>* form;

@property (nonatomic, strong) NSMutableDictionary * mDictionary;

#pragma mark - ================<离线工单相关>===============
//@property (nonatomic, assign) BOOL isUpLoadFaild;/**是否提交离线工单失败 */
@property (nonatomic, assign) BOOL isActionOffLine;//用户是否操作过，提交成功后需要更改为假。
@property (nonatomic, strong) NSDictionary *offLineSubmitData;/**离线提交数据 - 工单里面所有的提交数据 */



+ (instancetype)initWithDictionary:(NSDictionary*)dictionary;

@end
